package com.xiaoyang.forum.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.xiaoyang.forum.domain.dto.UserPasswordDTO;
import com.xiaoyang.forum.domain.dto.UserUpdateDTO;
import com.xiaoyang.forum.domain.pojo.User;
import com.xiaoyang.forum.domain.vo.UserDetailsVO;
import com.xiaoyang.forum.domain.vo.UserVO;

public interface IUserService extends IService<User> {
    void registerUser(String username, String password);

    String login(String username, String password);

    UserVO getUserInfo(String token);

    UserDetailsVO getUserAndArticleInfo(Long userId);

    int modifyUserInfo(long userId, UserUpdateDTO userUpdateDTO);

    int modifyPassword(long userId, UserPasswordDTO userPasswordDTO);

    Boolean sendCode(String email);

    String codeLogin(String email, String code);

    int updateHeadImage(String avatarUrl, long userId);
}